package SevenWeek;

import java.util.ArrayList;
import java.util.List;
import java.util.Scanner;

interface StringStack {
	public String push(String item);

	public String pop();

	public String peek();

	public boolean empty();

	public int size();
}

class ArrayListStringStack implements StringStack {
	private List<String> list;

	public ArrayListStringStack() {
		list = new ArrayList<String>();
	}

	@Override
	public String push(String item) {
		if (item == null)
			return null;
		list.add(item);
		return item;
	}

	@Override
	public String pop() {
		if (list.isEmpty())
			if (list.size() == 0)
				return null;
		return list.remove(list.size() - 1);
	}

	@Override
	public String peek() {
		if (list.size() == 0)
			return null;
		return list.get(size() - 1);
	}

	@Override
	public boolean empty() {
		if (list.size() == 0)
			return true;
		return false;
	}

	@Override
	public int size() {
		return list.size();
	}

	@Override
	public String toString() {
		return list.toString();
	}

}

public class Main201521123082 {
	public static void main(String[] args) {
		Scanner input = new Scanner(System.in);
		while (input.hasNext()) {
			String string = input.next();
			System.out.println(isPalindromeNumber(string));
		}
	}

	public static boolean isPalindromeNumber(String string) {
		ArrayListStringStack list = new ArrayListStringStack();
		char[] Array = string.toCharArray();
		for (int i = 0; i < Array.length / 2; i++) {
			list.push(String.valueOf(Array[i]));
		}
		for (int i = Array.length / 2; i < Array.length; i++) {
			if (!list.pop().equals(String.valueOf(Array[i])))
				return false;
		}
		return true;
	}
}